/**********************************************
这是代码自动生成的，如果重新生成，所做的改动将会丢失
系统:gpssolution
模块:系统平台
Itop.com 版权所有
生成者：Rabbit
生成时间:2012-7-17 11:19:34
***********************************************/

using System;
using System.Threading;
using System.ComponentModel;
namespace Itop.GpsCar.Model
{
    /// <summary>
    ///[group]业务实体类
    ///对应表名:group
    /// </summary>
    [Serializable]
    public class group
    {
        
        #region Private 成员
        private int _groupid=0; 
        private string _group_name=String.Empty; 
        private string _group_description=String.Empty; 
        private DateTime _timestamp=new DateTime(1900,1,1);   
        #endregion
  
  
        #region Public 成员
   
        /// <summary>
        /// 属性名称：groupid
        /// 属性描述：
        /// 字段信息：[groupid],INT UNSIGNED
        /// </summary>
        [Browsable(false)]
        [DisplayNameAttribute("")]
        public int groupid
        {
            get { return _groupid; }
            set
            {			
                if (_groupid as object == null || !_groupid.Equals(value))
                {
                    _groupid = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：group_name
        /// 属性描述：
        /// 字段信息：[group_name],VARCHAR
        /// </summary>
        [DisplayNameAttribute("")]
        public string group_name
        {
            get { return _group_name; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 45)
                throw new Exception("[]长度不能大于45!");
                if (_group_name as object == null || !_group_name.Equals(value))
                {
                    _group_name = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：group_description
        /// 属性描述：
        /// 字段信息：[group_description],VARCHAR
        /// </summary>
        [DisplayNameAttribute("")]
        public string group_description
        {
            get { return _group_description; }
            set
            {			
                if(value==null)return;
                if( value.ToString().Length > 45)
                throw new Exception("[]长度不能大于45!");
                if (_group_description as object == null || !_group_description.Equals(value))
                {
                    _group_description = value;
                }
            }			 
        }
  
        /// <summary>
        /// 属性名称：timestamp
        /// 属性描述：
        /// 字段信息：[timestamp],TIMESTAMP
        /// </summary>
        [DisplayNameAttribute("")]
        public DateTime timestamp
        {
            get { return _timestamp; }
            set
            {			
                if (_timestamp as object == null || !_timestamp.Equals(value))
                {
                    _timestamp = value;
                }
            }			 
        }
  
        #endregion 
  
        #region 方法
        public static string Newid(){
            return DateTime.Now.ToString("yyyyMMddHHmmssffffff");
        }
        public string CreateID(){
            Thread.Sleep(new TimeSpan(100000));//0.1毫秒
            return DateTime.Now.ToString("yyyyMMddHHmmssffffff");
        }
        #endregion		
    }	
}
